package com.example.demo;

import org.noear.solon.annotation.Component;
import org.noear.solon.annotation.Mapping;
import org.noear.solon.core.handle.Gateway;

/**
 * @author airhead
 */
@Component
@Mapping("/admin-api/**")
public class AdminGateway extends Gateway {
  @Override
  protected void register() {
    // 注释有返回，不注释返回空
    //    filter(0, new AdminAuthFilter());

    // 添加Bean
    addBeans(bw -> "adminApi".equals(bw.tag()));
  }
}
